<?php
/**
 * post-read.phtml
 * 
 * layout for reading a single post
 * 
 * @category 	Madoqua
 * @package 	Layout
 * @subpackage 	Front
 */

$post = $this->placeholder('blog-post-read')->post;
//the post we're reading (comes from blog/post/read)

$this->headTitle($post->title);
//set the page title to the blog

$this->headLink()->appendStylesheet($this->themeFile('css/dikdik.css'));
//main dikdik style sheet

$this->headLink()->appendAlternate($this->urlFeed(), 'application/rss+xml', $this->config()->name);
$this->headLink()->appendAlternate($this->urlPostFeed($post), 'application/rss+xml', $post->title);
//add general feed link to the page

echo $this->doctype('XHTML1_STRICT');
//set display the doctype
?>
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
    
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <?php echo $this->head(); ?>
    </head>
    
    <body>
        <div id="all">
            
            <?php echo $this->partial('partials/menu.phtml'); ?>
            
            <div id="content">
                
                <div class="post">
    
                    <div id="single-post">
                        <div class="post-content">
                            <?php echo $this->layout()->content; //will contain results fromt post/read ?>
                        </div>
                    
                        <div class="post-categories">
                            <h3>Categories</h3>
                            <?php echo $this->action('categories', 'post', 'blog', array('post' => $this->post)); ?>
                        </div>
                    
                        <div id="single-post-bottom"></div>
                        
                    </div>
                    
                        
                    <div class="post-navigation">
                        <?php echo $this->action('prevnext', 'post', 'blog', array('post' => $post)); ?>
                    </div>
                    
                    <div class="post-comments">
                        <h3>Comments</h3>
                        <p class="desc">Listing comments for "<?php echo $this->post->title; ?>"</p>
                        <?php echo $this->action('list', 'comment', 'blog', array('post' => $post)); ?>
                    </div>
                    
                    <div class="post-comment-form">
                        <h3>Post a comment</h3>
                        <?php echo $this->action('create', 'comment', 'blog', array('post' => $post), true); //no cache ?>
                    </div>
                    
                </div>
                
            </div>
            
            <?php echo $this->partial('partials/footer.phtml'); ?>
            
        </div>
        
        
    </body>
</html>
